@extends("backend.master")
@section("content")
	<h2>{{$title}}</h2>
	
		<table class="table table-bordered table-striped table-hover">
			<tr>
				<a href="{{URL::route('registeruser_get')}}" class="btn btn-primary" >Thêm thành viên	</a>
			</tr>

			<tr class="info">
				<td>Username</td>
				<td>Email</td>
				<td>First name</td>
				<td>Last name</td>

				@if (Sentry::hasAccess("admin"))
				<td>Delete</td>
				@endif

			</tr>

			@foreach($users as $user)
				<tr>
					<td>{{$user->username}}</td>
					<td>{{$user->email}}</td>
					<td>{{$user->first_name}}</td>
					<td>{{$user->last_name}}</td>

					@if (Sentry::hasAccess("admin"))
					<td><a href="{{URL::route('deleteuser_post',array($user->id))}}"><img src="{{URL::to('/')}}/public/backend/images/delete.png" ></a></td>
					@endif

				</tr>
			@endforeach

		</table>
	
@endsection
@section("data_code")
	
@endsection